package com.dongqi.detectionResult.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * 检测结果
 * @TableName detection_result
 */
@TableName("detection_result")
public class DetectionResultEntity implements Serializable {
    /**
     * id
     */
    private Long id;

    /**
     * 设备编号
     */
    private String deviceNo;

    /**
     * 检测类型(1=护拦板安装检测;2=桩钉检测;3=路面检测)
     */
    private String detectType;

    /**
     * 检测任务段
     */
    private String detectTaskNo;

    /**
     * 检测结果(0=未通过;1=已通过)
     */
    private String detectResult;

    /**
     * 检测时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date detectTime;

    /**
     * 检测员
     */
    private String inspector;

    /**
     * 详情报告
     */
    private String detailReport;

    /**
     * 反馈结果
     */
    private String feedback;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;

    /**
     * 修改时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;

    /**
     * 备用1
     */
    private String bak1;

    /**
     * 备用2
     */
    private String bak2;

    /**
     * 备用3
     */
    private String bak3;

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    public Long getId() {
        return id;
    }

    /**
     * id
     */
    public void setId(Long id) {
        this.id = id;
    }

    /**
     * 设备编号
     */
    public String getDeviceNo() {
        return deviceNo;
    }

    /**
     * 设备编号
     */
    public void setDeviceNo(String deviceNo) {
        this.deviceNo = deviceNo;
    }

    /**
     * 检测类型(1=护拦板安装检测;2=桩钉检测;3=路面检测)
     */
    public String getDetectType() {
        return detectType;
    }

    /**
     * 检测类型(1=护拦板安装检测;2=桩钉检测;3=路面检测)
     */
    public void setDetectType(String detectType) {
        this.detectType = detectType;
    }

    /**
     * 检测任务段
     */
    public String getDetectTaskNo() {
        return detectTaskNo;
    }

    /**
     * 检测任务段
     */
    public void setDetectTaskNo(String detectTaskNo) {
        this.detectTaskNo = detectTaskNo;
    }

    /**
     * 检测结果(0=未通过;1=已通过)
     */
    public String getDetectResult() {
        return detectResult;
    }

    /**
     * 检测结果(0=未通过;1=已通过)
     */
    public void setDetectResult(String detectResult) {
        this.detectResult = detectResult;
    }

    /**
     * 检测时间
     */
    public Date getDetectTime() {
        return detectTime;
    }

    /**
     * 检测时间
     */
    public void setDetectTime(Date detectTime) {
        this.detectTime = detectTime;
    }

    /**
     * 检测员
     */
    public String getInspector() {
        return inspector;
    }

    /**
     * 检测员
     */
    public void setInspector(String inspector) {
        this.inspector = inspector;
    }

    /**
     * 详情报告
     */
    public String getDetailReport() {
        return detailReport;
    }

    /**
     * 详情报告
     */
    public void setDetailReport(String detailReport) {
        this.detailReport = detailReport;
    }

    /**
     * 反馈结果
     */
    public String getFeedback() {
        return feedback;
    }

    /**
     * 反馈结果
     */
    public void setFeedback(String feedback) {
        this.feedback = feedback;
    }

    /**
     * 创建时间
     */
    public Date getCreateTime() {
        return createTime;
    }

    /**
     * 创建时间
     */
    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    /**
     * 修改时间
     */
    public Date getUpdateTime() {
        return updateTime;
    }

    /**
     * 修改时间
     */
    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    /**
     * 备用1
     */
    public String getBak1() {
        return bak1;
    }

    /**
     * 备用1
     */
    public void setBak1(String bak1) {
        this.bak1 = bak1;
    }

    /**
     * 备用2
     */
    public String getBak2() {
        return bak2;
    }

    /**
     * 备用2
     */
    public void setBak2(String bak2) {
        this.bak2 = bak2;
    }

    /**
     * 备用3
     */
    public String getBak3() {
        return bak3;
    }

    /**
     * 备用3
     */
    public void setBak3(String bak3) {
        this.bak3 = bak3;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        DetectionResultEntity other = (DetectionResultEntity) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getDeviceNo() == null ? other.getDeviceNo() == null : this.getDeviceNo().equals(other.getDeviceNo()))
            && (this.getDetectType() == null ? other.getDetectType() == null : this.getDetectType().equals(other.getDetectType()))
            && (this.getDetectTaskNo() == null ? other.getDetectTaskNo() == null : this.getDetectTaskNo().equals(other.getDetectTaskNo()))
            && (this.getDetectResult() == null ? other.getDetectResult() == null : this.getDetectResult().equals(other.getDetectResult()))
            && (this.getDetectTime() == null ? other.getDetectTime() == null : this.getDetectTime().equals(other.getDetectTime()))
            && (this.getInspector() == null ? other.getInspector() == null : this.getInspector().equals(other.getInspector()))
            && (this.getDetailReport() == null ? other.getDetailReport() == null : this.getDetailReport().equals(other.getDetailReport()))
            && (this.getFeedback() == null ? other.getFeedback() == null : this.getFeedback().equals(other.getFeedback()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
            && (this.getBak1() == null ? other.getBak1() == null : this.getBak1().equals(other.getBak1()))
            && (this.getBak2() == null ? other.getBak2() == null : this.getBak2().equals(other.getBak2()))
            && (this.getBak3() == null ? other.getBak3() == null : this.getBak3().equals(other.getBak3()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getDeviceNo() == null) ? 0 : getDeviceNo().hashCode());
        result = prime * result + ((getDetectType() == null) ? 0 : getDetectType().hashCode());
        result = prime * result + ((getDetectTaskNo() == null) ? 0 : getDetectTaskNo().hashCode());
        result = prime * result + ((getDetectResult() == null) ? 0 : getDetectResult().hashCode());
        result = prime * result + ((getDetectTime() == null) ? 0 : getDetectTime().hashCode());
        result = prime * result + ((getInspector() == null) ? 0 : getInspector().hashCode());
        result = prime * result + ((getDetailReport() == null) ? 0 : getDetailReport().hashCode());
        result = prime * result + ((getFeedback() == null) ? 0 : getFeedback().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        result = prime * result + ((getBak1() == null) ? 0 : getBak1().hashCode());
        result = prime * result + ((getBak2() == null) ? 0 : getBak2().hashCode());
        result = prime * result + ((getBak3() == null) ? 0 : getBak3().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", deviceNo=").append(deviceNo);
        sb.append(", detectType=").append(detectType);
        sb.append(", detectTaskNo=").append(detectTaskNo);
        sb.append(", detectResult=").append(detectResult);
        sb.append(", detectTime=").append(detectTime);
        sb.append(", inspector=").append(inspector);
        sb.append(", detailReport=").append(detailReport);
        sb.append(", feedback=").append(feedback);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", bak1=").append(bak1);
        sb.append(", bak2=").append(bak2);
        sb.append(", bak3=").append(bak3);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}